package com.example.yin.dao;

import com.example.yin.domain.Song;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface SongMapper {
    /*user module*/

    List<Song> queryBySongname(String str);//根据歌曲名和歌手名模糊搜索
    Song selectById(Integer id);//根据id进行搜索
    int updateById(Song record);//根据id更新歌曲信息


    /*admin module*/
//    int deleteByPrimaryKey(Integer id);
//    int insert(Song record);
//    int insertSelective(Song record);
//    int updateByPrimaryKeySelective(Song record);
//    int updateByPrimaryKeyWithBLOBs(Song record);

    int addSong(Song record);

    int deleteSong(Integer id);

    int updateByPrimaryKey(Song record);


    /*public module*/

    List<Song> allSong();

    List<Song> songOfSingerName(String name);

    List<Song> songOfName(String name);

    List<Song> songOfSingerId(Integer singerId);

//    List<Song> songOfId(Integer id);

    int updateSongMsg(Song record);

    int updateSongUrl(Song record);

    int updateSongPic(Song record);


}
